from pydantic.dataclasses import dataclass, Field
from typing import List, Dict, Optional


@dataclass
class BaseCommand:
    id: int
    command: str
    arguments: List[str]
    working_directory: str
    environ: Dict[str, str]
    input_files: List[str] = Field(default_factory=list)
    output_file: Optional[str] = Field(default=None)

    def __hash__(self) -> int:
        return self.id
